package websocket;

import static spark.Spark.*;

public class StartChat {
    public static void main(String[] args) {
        staticFileLocation("/public");
        port(4567);
        webSocket("/talkWithServer", TalkWithServerHandler.class);
        webSocket("/broadcast", BroadcastHandler.class);
        webSocket("/talkWithUser", TalkWithUserHandler.class);
        webSocket("/json", JSONHandler.class);
        // 如果在WebSocket路由后没有定义HTTP路由，则需要使用
        init();
    }
}
